package com.mk.cloud.common.domain;
import org.beetl.sql.core.annotatoin.AssignID;
import org.beetl.sql.core.annotatoin.Param;
import org.beetl.sql.core.mapper.BaseMapper;

import javax.persistence.Transient;
import java.io.Serializable;
import java.math.*;
import java.util.Date;
import java.sql.Timestamp;

/*
* 
* gen by beetlsql 2018-04-04
*/
public class PScheme   implements Serializable{
	//方案主键
	@AssignID
	private String sid ;
	//品牌id
	private String brid ;
	//创建时间
	private String createtime ;
	//发布状态（0草稿，1已发布，2已删除）
	private String publishstatus ;
	//发布时间
	private String publishtime ;
	//发布人id
	private String publishuserid ;
	//方案金额
	private BigDecimal samount ;
	//方案描述
	private String sdescribe ;
	//方案名称
	private String sname ;
	//品牌名称
	@Transient
	private String brname ;
	//发布人姓名
	@Transient
	private String realname ;

	private String coid;

	public String getCoid() {
		return coid;
	}

	public void setCoid(String coid) {
		this.coid = coid;
	}

	public PScheme() {
	}

	public String getBrname() {
		return brname;
	}

	public void setBrname(String brname) {
		this.brname = brname;
	}

	public String getRealname() {
		return realname;
	}

	public void setRealname(String realname) {
		this.realname = realname;
	}

	public String getSid(){
		return  sid;
	}
	public void setSid(String sid ){
		this.sid = sid;
	}
	
	public String getBrid(){
		return  brid;
	}
	public void setBrid(String brid ){
		this.brid = brid;
	}
	
	public String getCreatetime(){
		return  createtime;
	}
	public void setCreatetime(String createtime ){
		this.createtime = createtime;
	}
	
	public String getPublishstatus(){
		return  publishstatus;
	}
	public void setPublishstatus(String publishstatus ){
		this.publishstatus = publishstatus;
	}
	
	public String getPublishtime(){
		return  publishtime;
	}
	public void setPublishtime(String publishtime ){
		this.publishtime = publishtime;
	}
	
	public String getPublishuserid(){
		return  publishuserid;
	}
	public void setPublishuserid(String publishuserid ){
		this.publishuserid = publishuserid;
	}
	
	public BigDecimal getSamount(){
		return  samount;
	}
	public void setSamount(BigDecimal samount ){
		this.samount = samount;
	}
	
	public String getSdescribe(){
		return  sdescribe;
	}
	public void setSdescribe(String sdescribe ){
		this.sdescribe = sdescribe;
	}
	
	public String getSname(){
		return  sname;
	}
	public void setSname(String sname ){
		this.sname = sname;
	}

	public interface Mapper extends BaseMapper<PScheme> {

		/**
		 * 查看编码是否与方案金额匹配,匹配则 返回方案 主键:sid
		 * @param pscode
		 * @param samount
		 * @return
		 */
		String getByCodeAndAmount(@Param("pscode")String pscode,@Param("samount")BigDecimal samount);
	}
	

}
